-- GENERATED SPELL FOR [En'kilah Necrolord] --


function spell0_25730(pUnit, Event) --@Cleave,n/a--
pUnit:FullCastSpellOnTarget(16044,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_25730', 617, 1)
end

function spell1_25730(pUnit, Event) --@Mortal Strike,n/a--
pUnit:FullCastSpellOnTarget(24573,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_25730', 5286, 1)
end

function spell2_25730(pUnit, Event) --@Saurfang\'s Rage,n/a--
pUnit:FullCastSpellOnTarget(45950,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_25730', 20318, 1)
end

function spell3_25730(pUnit, Event) --@Shield Charge,n/a--
pUnit:FullCastSpellOnTarget(15749,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_25730', 543, 1)
end

function spell4_25730(pUnit, Event) --@Terrifying Roar,Self--
pUnit:FullCastSpellOnTarget(14100,pUnit)
pUnit:RegisterEvent('Sorts_25730', 5320, 1)
end

function spell5_25730(pUnit, Event) --@Whirlwind,n/a--
pUnit:FullCastSpellOnTarget(41097,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_25730', 15000, 1)
end

function spell6_25730(pUnit, Event) --@Whirlwind,Self--
pUnit:FullCastSpellOnTarget(41098,pUnit)
pUnit:RegisterEvent('Sorts_25730', 529, 1)
end

function Sorts_25730(pUnit, Event)
local choix_sorts_25730 = math.random(0, 6)
if choix_sorts_25730 == 0 then
pUnit:RegisterEvent('spell0_25730', 1, 1)
end
if choix_sorts_25730 == 1 then
pUnit:RegisterEvent('spell1_25730', 1, 1)
end
if choix_sorts_25730 == 2 then
pUnit:RegisterEvent('spell2_25730', 1, 1)
end
if choix_sorts_25730 == 3 then
pUnit:RegisterEvent('spell3_25730', 1, 1)
end
if choix_sorts_25730 == 4 then
pUnit:RegisterEvent('spell4_25730', 1, 1)
end
if choix_sorts_25730 == 5 then
pUnit:RegisterEvent('spell5_25730', 1, 1)
end
if choix_sorts_25730 == 6 then
pUnit:RegisterEvent('spell6_25730', 1, 1)
end
end

function mob25730_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_25730', math.random(1500, 3000), 1)
end

function mob25730_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob25730_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob25730_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(25730, 1, 'mob25730_Action')
RegisterUnitEvent(25730, 2, 'mob25730_Leave')
RegisterUnitEvent(25730, 3, 'mob25730_Kill')
RegisterUnitEvent(25730, 4, 'mob25730_Die')
